// ******************************************************************
// * Copyright(c)  Steven Lu
// * Description   : Entity_PROD_PRODUCT_TECHNIC
// * CreateDate    : 2012-09-26 18:10:01
// * Creater       : CodeSmith
// * LastChangeDate: 2012-09-26 18:10:01
// * LastChanger   : 2012-09-26 18:10:01
// * Version Info  : 1.0 For ESOL
// ******************************************************************

using System;
using System.Data;
using System.Collections.Generic;
using System.Text;
using Suzsoft.Smart.EntityCore;
using ESOL.Common.Schema;

namespace ESOL.Common.Entity
{
    [Serializable]
    public partial class ProdProductTechnicEntity : EntityBase
    {
        public ProdProductTechnicTable TableSchema
        {
            get
            {
                return ProdProductTechnicTable.Current;
            }
        }

        public ProdProductTechnicEntity()
        {

        }

        public ProdProductTechnicEntity(DataRow dr)
        {
            if (dr == null)
            {
                return;
            }
            this.ProductTechnicId = Convert.ToString(CommonFunctions.ToObject(dr["PRODUCT_TECHNIC_ID"]));
            this.PlanOrderItemId = Convert.ToString(CommonFunctions.ToObject(dr["PLAN_ORDER_ITEM_ID"]));
            this.TechnicId = Convert.ToString(CommonFunctions.ToObject(dr["TECHNIC_ID"]));
            this.GroupId = Convert.ToString(CommonFunctions.ToObject(dr["GROUP_ID"]));
            this.Sequence = Convert.ToInt32(CommonFunctions.ToObject(dr["SEQUENCE"]));
            this.Qty = Convert.ToDecimal(CommonFunctions.ToObject(dr["QTY"]));
            this.Price = Convert.ToDecimal(CommonFunctions.ToObject(dr["PRICE"]));
            this.GroupPerson = Convert.ToString(CommonFunctions.ToObject(dr["GROUP_PERSON"]));
            this.PlanWorkingHours = Convert.ToDecimal(CommonFunctions.ToObject(dr["PLAN_WORKING_HOURS"]));
            this.Cost = Convert.ToDecimal(CommonFunctions.ToObject(dr["COST"]));
            this.Coefficient = Convert.ToDecimal(CommonFunctions.ToObject(dr["COEFFICIENT"]));
            this.PurApplicationItemId = Convert.ToString(CommonFunctions.ToObject(dr["PUR_APPLICATION_ITEM_ID"]));
            this.DeliveryDate = Convert.ToDateTime(CommonFunctions.ToObject(dr["DELIVERY_DATE"]));
            this.PlanStarttime = Convert.ToDateTime(CommonFunctions.ToObject(dr["PLAN_STARTTIME"]));
            this.Remark = Convert.ToString(CommonFunctions.ToObject(dr["REMARK"]));
        }

        public ProdProductTechnicEntity(DataRowView dr)
        {
            if (dr == null)
            {
                return;
            }
            this.ProductTechnicId = Convert.ToString(CommonFunctions.ToObject(dr["PRODUCT_TECHNIC_ID"]));
            this.PlanOrderItemId = Convert.ToString(CommonFunctions.ToObject(dr["PLAN_ORDER_ITEM_ID"]));
            this.TechnicId = Convert.ToString(CommonFunctions.ToObject(dr["TECHNIC_ID"]));
            this.GroupId = Convert.ToString(CommonFunctions.ToObject(dr["GROUP_ID"]));
            this.Sequence = Convert.ToInt32(CommonFunctions.ToObject(dr["SEQUENCE"]));
            this.Qty = Convert.ToDecimal(CommonFunctions.ToObject(dr["QTY"]));
            this.Price = Convert.ToDecimal(CommonFunctions.ToObject(dr["PRICE"]));
            this.GroupPerson = Convert.ToString(CommonFunctions.ToObject(dr["GROUP_PERSON"]));
            this.PlanWorkingHours = Convert.ToDecimal(CommonFunctions.ToObject(dr["PLAN_WORKING_HOURS"]));
            this.Cost = Convert.ToDecimal(CommonFunctions.ToObject(dr["COST"]));
            this.Coefficient = Convert.ToDecimal(CommonFunctions.ToObject(dr["COEFFICIENT"]));
            this.PurApplicationItemId = Convert.ToString(CommonFunctions.ToObject(dr["PUR_APPLICATION_ITEM_ID"]));
            this.DeliveryDate = Convert.ToDateTime(CommonFunctions.ToObject(dr["DELIVERY_DATE"]));
            this.PlanStarttime = Convert.ToDateTime(CommonFunctions.ToObject(dr["PLAN_STARTTIME"]));
            this.Remark = Convert.ToString(CommonFunctions.ToObject(dr["REMARK"]));
        }

        public override TableInfo OringTableSchema
        {
            get
            {
                return ProdProductTechnicTable.Current;
            }
        }

        #region Perporty List
        public string ProductTechnicId
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_PRODUCT_TECHNIC_ID)); }
            set { SetData(ProdProductTechnicTable.C_PRODUCT_TECHNIC_ID, value); }
        }

        public string PlanOrderItemId
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_PLAN_ORDER_ITEM_ID)); }
            set { SetData(ProdProductTechnicTable.C_PLAN_ORDER_ITEM_ID, value); }
        }

        public string TechnicId
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_TECHNIC_ID)); }
            set { SetData(ProdProductTechnicTable.C_TECHNIC_ID, value); }
        }

        public string GroupId
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_GROUP_ID)); }
            set { SetData(ProdProductTechnicTable.C_GROUP_ID, value); }
        }

        public int Sequence
        {
            get { return Convert.ToInt32(GetData(ProdProductTechnicTable.C_SEQUENCE)); }
            set { SetData(ProdProductTechnicTable.C_SEQUENCE, value); }
        }

        public decimal Qty
        {
            get { return Convert.ToDecimal(GetData(ProdProductTechnicTable.C_QTY)); }
            set { SetData(ProdProductTechnicTable.C_QTY, value); }
        }

        public decimal Price
        {
            get { return Convert.ToDecimal(GetData(ProdProductTechnicTable.C_PRICE)); }
            set { SetData(ProdProductTechnicTable.C_PRICE, value); }
        }

        public string GroupPerson
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_GROUP_PERSON)); }
            set { SetData(ProdProductTechnicTable.C_GROUP_PERSON, value); }
        }

        public decimal PlanWorkingHours
        {
            get { return Convert.ToDecimal(GetData(ProdProductTechnicTable.C_PLAN_WORKING_HOURS)); }
            set { SetData(ProdProductTechnicTable.C_PLAN_WORKING_HOURS, value); }
        }

        public decimal Cost
        {
            get { return Convert.ToDecimal(GetData(ProdProductTechnicTable.C_COST)); }
            set { SetData(ProdProductTechnicTable.C_COST, value); }
        }

        public decimal Coefficient
        {
            get { return Convert.ToDecimal(GetData(ProdProductTechnicTable.C_COEFFICIENT)); }
            set { SetData(ProdProductTechnicTable.C_COEFFICIENT, value); }
        }

        public string PurApplicationItemId
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_PUR_APPLICATION_ITEM_ID)); }
            set { SetData(ProdProductTechnicTable.C_PUR_APPLICATION_ITEM_ID, value); }
        }

        public DateTime DeliveryDate
        {
            get { return Convert.ToDateTime(GetData(ProdProductTechnicTable.C_DELIVERY_DATE)); }
            set { SetData(ProdProductTechnicTable.C_DELIVERY_DATE, value); }
        }

        public DateTime PlanStarttime
        {
            get { return Convert.ToDateTime(GetData(ProdProductTechnicTable.C_PLAN_STARTTIME)); }
            set { SetData(ProdProductTechnicTable.C_PLAN_STARTTIME, value); }
        }

        public string Remark
        {
            get { return Convert.ToString(GetData(ProdProductTechnicTable.C_REMARK)); }
            set { SetData(ProdProductTechnicTable.C_REMARK, value); }
        }

        #endregion
    }


}

